<div class="modal hide fade" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
 <?= form_open('user/to_do/update_todo')?>
  <div class="modal-header">
  <button type="button" class="close" data-dismiss="modal" aria-hidden="true">x</button>
    <h3 id="myModalLabel">Edit Todo</h3>
  </div>
  <div class="modal-body">  
  <input  type="hidden" value="<?php echo $todo['id'];?>" name="id"/>  
  <input  type="hidden" value="<?php echo $todo['user_id'];?>" name="user_id"/>  
  <textarea class="span5" name="desc" style="display:none"><?php echo $todo['des'];?></textarea>
   <textarea class="span5" name="desc"><?php echo strip_tags($todo['des']);?></textarea>
  <?php 
	$cmonth = date('m');
	?>
	<br />
	Date: <input  type="text" class="span1" name="date" value="<?php echo $todo['date_id']?>" id="date"/>
	<select name="month" class="span2" id="month">       
        <option value="1" <?php if($todo['month_id'] == '01'){echo 'selected="selected"';} ?> >January</option>
        <option value="2" <?php if($todo['month_id'] == '02'){echo 'selected="selected"';} ?> >February</option>
        <option value="3" <?php if($todo['month_id'] == '03'){echo 'selected="selected"';} ?> >March</option>
        <option value="4" <?php if($todo['month_id'] == '04'){echo 'selected="selected"';} ?> >April</option>
        <option value="5" <?php if($todo['month_id'] == '05'){echo 'selected="selected"';} ?> >May</option>
        <option value="6" <?php if($todo['month_id'] == '06'){echo 'selected="selected"';} ?> >June</option>
        <option value="7" <?php if($todo['month_id'] == '07'){echo 'selected="selected"';} ?> >July</option>
        <option value="8" <?php if($todo['month_id'] == '08'){echo 'selected="selected"';} ?> >August</option>
        <option value="9" <?php if($todo['month_id'] == '09'){echo 'selected="selected"';} ?> >September</option>
        <option value="10" <?php if($todo['month_id'] == '10'){echo 'selected="selected"';} ?> >October</option>
        <option value="11" <?php if($todo['month_id'] == '11'){echo 'selected="selected"';} ?> >November</option>
        <option value="12" <?php if($todo['month_id'] == '12'){echo 'selected="selected"';} ?> >December</option>
    </select>
	<select class="span1" name="year">
		<option value="13">2013</option>
	</select>
	<br>
	<!--Priority: <select name="priority_is"><option value="<?php echo $todo['priority'];?>"><?php echo ucfirst($todo['priority']); ?></option><option value="">No Priority</option><option value="low">Low</option><option value="medium">Medium</option><option value="high">High</option></select>-->
	
	Priority: <select name="priority_is"><option value="">No Priority</option>
		<option value="low" <?php if($todo['priority'] == 'low'){echo 'selected="selected"';} ?>>Low</option>
			<option value="medium" <?php if($todo['priority'] == 'medium'){echo 'selected="selected"';} ?>>Medium</option>
			<option value="high" <?php if($todo['priority'] == 'high'){echo 'selected="selected"';} ?>>High</option></select>
	
  </div>
  <div class="modal-footer">
    <button class="btn" data-dismiss="modal" aria-hidden="true">Close</button>
    <button class="btn btn-info" type="submit">Save changes</button>
  </form>
  </div>
</div>

